import "./App.css"
import React from "react"
import {useRef,useEffect} from "react"

import Pag2 from "./rrouterComponents/Page2"

// let mydiv = React.createRef()

function App(){
  // let mydiv2 = useRef()
  let myPage2 = useRef()
  useEffect(()=>{
    console.log("获取子组件的属性和方法",myPage2)
  },[])

  return <div className="App" >
    测试ref和context
    <Pag2 ref = {myPage2}></Pag2>
  </div>
}



export default App